package com.edu.springmvc.helloworld.exception;

import lombok.Getter;

@Getter
public enum BusinessExceptionEnum {
    USER_NOT_EXIST(10001, "用户不存在"),
    USER_PASSWORD_ERROR(10002, "用户密码错误"),
    USER_NOT_LOGIN(10003, "用户未登录"),
    USER_NOT_ADMIN(10004, "用户不是管理员"),
    USER_NOT_LOGOUT(10005, "用户未登出"),
    USER_NOT_LOGIN_OR_LOGOUT(10006, "用户未登录或未登出"),
    USER_NOT_LOGIN_OR_ADMIN(10007, "用户未登录或未管理员"),
    USER_NOT_LOGIN_OR_LOGOUT_OR_ADMIN(10008, "用户未登录或未登出或未管理员");

    private final Integer code;
    private final String message;

    BusinessExceptionEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }
}
